/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package br.edu.fatec.ads.classes;

import javax.persistence.Column;
import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;

/**
 *
 * @author Bruno Moura
 */
@Entity
@DiscriminatorValue("3")
public class Aluno extends PessoaComplemento {

    private long matricula;

    public Aluno() {    super("3");    }

    /**
     * @return the matricula
     */
    @Column(name="cd_matricula", length=7, nullable=false)
    public long getMatricula() {
        return matricula;
    }

    /**
     * @param matricula the matricula to set
     */
    public void setMatricula(long matricula) {
        this.matricula = matricula;
    }

    @Override
    public String toString() {
        return "Aluno[pessoa=" + super.getPessoa().getCodigo()
                + ", matricula=" + this.getMatricula() + "]";
    }

}
